home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 23 / CU Amiga - Super CD-ROM 23 (June 1998).iso / CreatingGames / Utilities / Misc / GraphicsCode / examples / copper_test.s < prev    next >
Encoding:
Text File  |  1996-02-05  |  1000 b   |  55 lines

  1.  
  2. ;    Simple Copper List Demo coded in asm
  3. ;    Coded using devpac 3.
  4. ;    Probably needs tweaked for other assemblers.
  5.  
  6.  
  7.     include    system.gs        Include all of the system includes
  8.     include    graphics_base.i        Include My graphics Data
  9.  
  10.     bsr    Graphics_Init        Initialise the graphics system
  11.     
  12.     move.l    #320,d0
  13.     move.l    #256,d1
  14.     move.l    #8,d2
  15.     move.l    #0,d3
  16.     lea    colortable,a0
  17.     bsr    Open_Screen        Open a new view screen
  18.  
  19.     move.l    d0,screen        store the screen
  20.  
  21.     OFF_SPRITE            Turn off the sprites
  22.     move.l    screen,a0
  23.     lea    Copper_List,a1
  24.  
  25.     bsr    Add_Copper        Load a new copper list into screen
  26. pos
  27.     CHECK_CLICK
  28.     bne.s    pos            Wait for a mouse click
  29.  
  30.     ON_SPRITE            Sprites on
  31.  
  32.     move.l    screen,a0
  33.     bsr    Close_Screen        Close the screen
  34.     
  35.     bsr    Graphics_Close        close the graphics    
  36.     rts
  37.  
  38. screen
  39.     ds.l    1
  40. colortable
  41.     include    palette.s        palette data
  42.  
  43.     include    graphics_base.s        My graphics source        
  44.  
  45.     Section     Copper Lists,DATA
  46.  
  47. Copper_List
  48.     CWAIT    200,0               wait for line 200
  49.     CMOVE    $180,$0f0f
  50.     CWAIT    15,0
  51.     CMOVE    $180,$fff
  52.     CEND            end of list
  53.  
  54.     
  55.